import request from '@/utils/request'
//会员列表
export function getVipList(data) {
  return request({
    url: '/backend/user/list',
    method: 'post',
    data
  })
}
//冻结会员
export function editVip(data) {
  return request({
    url: '/backend/user/update',
    method: 'post',
    data
  })
}
//获取角色列表 
export function getRoleList(data) {
  return request({
    url: '/backend/role/list',
    method: 'post',
    data
  })
}
//添加角色
export function addRole(data) {
  return request({
    url: '/backend/role/add',
    method: 'post',
    data
  })
}
//删除角色
export function delRole(data) {
  return request({
    url: '/backend/role/delete',
    method: 'post',
    data
  })
}
//编辑角色
export function editRole(data) {
  return request({
    url: '/backend/role/update',
    method: 'post',
    data
  })
}
//添加角色权限
export function addRolePermission(data) {
  return request({
    url: '/backend/role/add/permission',
    method: 'post',
    data
  })
}
//删除角色权限
export function delRolePermission(data) {
  return request({
    url: '/backend/role/delete/permission',
    method: 'post',
    data
  })
}
//获取权限列表
export function getPermissionList(data) {
  return request({
    url: '/backend/permission/list',
    method: 'post',
    data
  })
}
//添加权限
export function addPermission(data) {
  return request({
    url: '/backend/permission/add',
    method: 'post',
    data
  })
}
//删除权限
export function delPermission(data) {
  return request({
    url: '/backend/permission/delete',
    method: 'post',
    data
  })
}
//编辑权限
export function editPermission(data) {
  return request({
    url: '/backend/permission/update',
    method: 'post',
    data
  })
}

//获取admin列表
export function getAdminList(data) {
  return request({
    url: '/backend/admin/list',
    method: 'post',
    data
  })
}
//添加用户
export function addAdmin(data) {
  return request({
    url: '/backend/admin/add',
    method: 'post',
    data
  })
}
//删除用户
export function delAdmin(data) {
  return request({
    url: '/backend/admin/delete',
    method: 'post',
    data
  })
}
//编辑用户
export function editAdmin(data) {
  return request({
    url: '/backend/admin/update',
    method: 'post',
    data
  })
}
//修改用户密码
export function editAdminPassword(data) {
  return request({
    url: '/backend/admin/update/password',
    method: 'post',
    data
  })
}

